<?php
/**
 * 小邮筒订单
 */
namespace soa\minpost\order\v1\common;

use soa\client;

//订单与外部关联
class orderConn  extends client
{
	/**
	 * 服务地址
	 * @var string
	 */
	public $service_url = 'http://mp.kuaidihelp.com/';

	/**
	 * 服务名称
	 * @var string
	 */
	protected $service_name = 'kuaidihelp_mp';

	//添加关联记录
	public function insert($orderId,$thirdOrderId,$thirdOrderPlatform, $extraInfo = [])
	{
		return $this->post("api/cloudPrint/order/v1/common/orderConn/insert", compact('orderId',"thirdOrderId","thirdOrderPlatform","extraInfo"));
	}

	//根据订单号获取
	public function getByOrderId($orderId){
		return $this->post("api/cloudPrint/order/v1/common/orderConn/getByOrderId", compact('orderId'));
	}

	//根据第三方平台订单获取
	public function getByThirdOrderId($thirdOrderId,$thirdOrderPlatform){
		return $this->post("api/cloudPrint/order/v1/common/orderConn/getByThirdOrderId", compact("thirdOrderId","thirdOrderPlatform"));
	}
}